﻿
namespace Domain.Setup.Entities
{
    /// <summary>
    /// The task class represents a task that can be performed by a StaffMember
    /// </summary>
    public class Task
    {
        #region Public Properties
        /// <summary>
        /// Gets the unique id of the Task.
        /// </summary>
        public int Id { get; private set; }

        /// <summary>
        /// Gets the skill required to perform the Task.
        /// </summary>
        public virtual Skill RequiredSkill { get; set; }

        /// <summary>
        /// Gets or sets the name of the Task.
        /// </summary>
        /// <value>
        /// The name.
        /// </value>
        public string Name { get; set; }

        /// <summary>
        /// Gets or sets the task description.
        /// </summary>
        /// <value>
        /// The description.
        /// </value>
        public string Description { get; set; }

        /// <summary>
        /// Gets or sets a value indicating whether this instance is active.
        /// </summary>
        /// <value>
        ///   <c>true</c> if this instance is active; otherwise, <c>false</c>.
        /// </value>
        public bool IsActive { get; set; } 
        #endregion

        /// <summary>
        /// Changes the skill required to perform this Task.
        /// </summary>
        /// <param name="skill">The skill.</param>
        public void ChangeRequiredSkill(Skill skill)
        {
            this.RequiredSkill = skill;
        }
    }
}
